package com.ksyun.ks3.util;

import java.util.Iterator;
import java.util.Map;
import java.util.Map.Entry;

import okhttp3.Headers;

public class ModelUtil {

    public static Headers convertHeaderArray(Map<String, String> sourceMap) {
        Iterator<Entry<String, String>> iterator = sourceMap.entrySet()
                .iterator();
        Headers.Builder builder = new Headers.Builder();
        while (iterator.hasNext()) {
            final Map.Entry<String, String> entry = iterator.next();
            builder.add(entry.getKey(), entry.getValue());
        }
        return builder.build();
    }
//
//	public static RequestParams convertRequestParams(
//			Map<String, String> sourceMap) {
//		return new RequestParams(sourceMap);
//	}
}
